

function sleep(a){

  return new Promise (resolve =>{
    setTimeout(function(){
      let b = a/1000;
      console.log(b+"秒")
    },a)
  });
}

async function test(){

  let test1 = await sleep(2000);
  // let test2 = await sleep(2000);
  // console.log(test1,test2);
}
test();

// async function test(){
//
//   // let test1 = await sleep(1000);
//   let test2 = await sleep(2000);
//   // console.log(test1,test2);
// }
// test();
